package com.gxitsky.current;

import org.springframework.scheduling.annotation.Async;

import java.util.ArrayList;
import java.util.List;
import java.util.concurrent.Future;

/**
 * @author gxing
 * @desc TODO
 * @date 2022/5/22
 */
public class MainTest {

    @Async()
    public void test1(){
        List<Month> list = new ArrayList<>();
        for(int i = 0 ; i < 12 ; i ++) {
            Month month = statOneMonthData(i); // 计算某个月的数据，逻辑比较复杂，难以批量计算，效率也无法很高
            list.add(month);
        }
    }

    public Month statOneMonthData(int month){
        return new Month();
    }

}
